package org.code.mallspringboot.service.impl;

import org.code.mallspringboot.mapper.UmsRoleMapper;
import org.code.mallspringboot.pojo.UmsMenu;
import org.code.mallspringboot.pojo.UmsRole;
import org.code.mallspringboot.pojo.UmsRoleExample;
import org.code.mallspringboot.service.UmsRoleService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * 角色管理Service实现类
 * @author jamie
 */
@Service
public class UmsRoleServiceImpl implements UmsRoleService {

    @Autowired
    private UmsRoleMapper umsRoleMapper;

    @Override
    public List<UmsMenu> getMenuList(Long adminId) {
        return umsRoleMapper.getMenuList(adminId);
    }

    @Override
    public List<UmsRole> list() {
        return umsRoleMapper.selectByExample(new UmsRoleExample());
    }

}
